package com.wing.cabinet.model.entity;

import java.io.Serializable;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.wing.cabinet.utils.ExcelExport;
import com.wing.mybatis.common.BaseEntity;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import java.time.LocalDateTime;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * 呆滞物料管理
 *
 * @author
 */
@Data
@NoArgsConstructor
@Accessors(chain = true)
@TableName("cab_cell_sluggish_materials")
public class CellSluggishMaterials extends BaseEntity<CellSluggishMaterials> implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 创建者
     */
    private Long creator;

    /**
     * 修改者
     */
    private Long modifier;

    /**
     * 创建人
     */
    private String creatorName;

    /**
     * 修改人
     */
    private String modifierName;

    /**
     * sku编码
     */
    private String skuCode;

    /**
    * 上货时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime exhibitTime;

    /**
    * 领取时间
    */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime receiptorTime;

    /**
     * 企业编码
     */
    private String enterpriseCode;

    /**
     * sku 名称
     */
    @TableField(exist = false)
    private String skuName;

    /**
     * sku 规格
     */
    @TableField(exist = false)
    private String skuSpec;

    /**
     * 产品品牌
     */
    @TableField(exist = false)
    private String productBrandName;

    /**
     * 数量
     */
    @TableField(exist = false)
    private Integer quantity;

    /**
     * 包装数量
     */
    @TableField(exist = false)
    private Integer quantityPack;


    @TableField(exist = false)
    private String productTypeName;

    @TableField(exist = false)
    private String oldSpecCode;

    public String getOldSpecCode(){
        return this.skuSpec;
    }


    @TableField(exist = false)
    private String skuPic;

    @TableField(exist = false)
    private String unitName;
    @TableField(exist = false)
    private String basicsUnitName;
    @TableField(exist = false)
    /**
     * 呆滞时长阈值
     */
    private Integer lethargyThreshold;
}
